import QtQuick
import QtQuick.Layouts
import QtQuick.Controls

Item {
    id:root

    // Rectangle{
    //     id:background
    //     anchors.fill: parent
    //     color: "red"
    // }

    QtObject{
        id:comData
        property int buttonHeight: 40
        property int buttonWidth: root.width
    }

    Column{
        anchors.fill: parent
        spacing: 0

        Column{
            id:buttonBarTop
            Button{
                id:button1
                height: comData.buttonHeight
                width: comData.buttonWidth
                text: "计划"
            }
            Button{
                id:button2
                height: comData.buttonHeight
                width: comData.buttonWidth
                text: "Button - 2"
            }
            Button{
                id:button3
                height: comData.buttonHeight
                width: comData.buttonWidth
                text: "Button - 3"
            }
            Button{
                id:button4
                height: comData.buttonHeight
                width: comData.buttonWidth
                text: "Button - 4"
            }
        }

        Rectangle{
            id:springRectangle
            height: root.height-buttonBarTop.height-buttonBarBottom.height
            width: parent.width
            color:"green"
        }

        Rectangle{
            id:buttonBarBottom
            width: parent.width
            height: 80
            color:"yellow"
        }
    }

    Component.onCompleted: {
        console.log("Creating ManBarPage suceessfully")
    }
}
